'use strict';

const Controller = require('egg').Controller;
const mongoose = require('mongoose');
class userController extends Controller {
  async addCart() {
    const { ctx } = this;
    this.ctx.body = await this.ctx.service.user.addCart(ctx.request.body);
  }

  async userLogin(){
    const { ctx } = this;
    this.ctx.body = await this.ctx.service.user.userLogin(ctx.request.body);
  }

  async userInfor(){
    const { ctx } = this;
    this.ctx.body = await this.ctx.service.user.getUserInfor(ctx.request.body);
  }
}

module.exports = userController;
